package com.lanchetech.dao;

import com.lanchetech.bean.request.DepositReq;
import com.lanchetech.bean.vo.AnchorDepositVO;
import com.lanchetech.entity.AgencyDeposit;
import com.lanchetech.entity.AnchorDeposit;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface AnchorDepositMapper {
    int deleteByPrimaryKey(Long id);

    int insert(AnchorDeposit record);

    int insertAgency(AgencyDeposit record);

    int insertSelective(AnchorDeposit record);

    AnchorDeposit selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(AnchorDeposit record);

    int updateByPrimaryKey(AnchorDeposit record);

    AnchorDeposit findOneByTradeNo(@Param("tradeNo")String tradeNo);

    List<AnchorDepositVO> findAllPage(DepositReq req);

    int updateRefundStatusById(@Param("updatedRefundStatus")Byte updatedRefundStatus,@Param("id")Long id);

    AnchorDeposit findOneByAnchorUserIdAndPayStatus(@Param("anchorUserId")Long anchorUserId);

    AnchorDeposit findOneByRefundNo(@Param("refundNo")String refundNo);


}